#ifndef _FNT_OPTIONS_DLG_H_
#define _FNT_OPTIONS_DLG_H_

#include <QDialog>

class Session;
class OptionsPage;
class Options;
enum class SessionState;

class OptionsDlg : public QDialog {
	Q_OBJECT;
	struct Priv;
	Priv*const priv;

	static OptionsDlg* _instance;

	OptionsDlg();

	private Q_SLOTS:
		void stateChanged(bool a, bool b, bool c, bool d);
	void useDefault();
	void saveDefault();
	void applyChanges();
	void resetChanges();
	public:
	static OptionsDlg* instance() {
		if(!_instance)
			_instance=new OptionsDlg{};
		return _instance;
	}
	~OptionsDlg();

	void addPages(const QString& section, const QList<OptionsPage*>& pages);
	void setState(SessionState s);

	void dumpOptions(Options* opt);
};

#endif
